#include<bits/stdc++.h>
using namespace std;

int a[100], b[100];

int main() {
	int n;
	cin >> n;
	for (int i = 1; i <= n; i++) {
		cin >> a[i];
		b[i] = a[i];
	}

	sort(b + 1, b + n + 1);

	for (int i = 1; i <= n; i++) {
		int num = 0;
		for (int j = 1; j <= n; j++) {
			if (b[j] != b[j - 1])
				num++;
			if (a[i] == b[j]) {
				cout << num << endl;
				break;
			}
		}
	}
	return 0;
}
